#![crate_name = "gayboy"]
// bash: rustc --help | grep crate-type
#![crate_type = "staticlib"]

pub use crate::keypad::KeypadKey;
pub use clap_args::build_app_args;
pub use coreutils::main_utils::construct_cpu;
pub use coreutils::main_utils::create_window_builder;
pub use coreutils::main_utils::recalculate_screen;
pub use coreutils::main_utils::run_cpu;
pub use coreutils::main_utils::run_test_mode;
pub use coreutils::main_utils::set_window_size;
pub use coreutils::main_utils::winit_to_keypad;
pub use coreutils::main_utils::RenderOptions;
pub use gbevent::GBEvent;
pub use gpu::SCREEN_HEIGHT;
pub use gpu::SCREEN_WIDTH;
pub use player::cpalplayer::CpalPlayer;
pub use sound::interface::IAudioPlayer;

pub mod clap_args;
mod cpu;
mod device;
mod gbevent;
mod gbmode;
mod gpu;
mod keypad;
mod mbc;
mod mmu;
mod player;
mod printer;
mod register;
mod serial;
mod sound;
mod timer;

mod coreutils;

pub type StrResult<T> = Result<T, &'static str>;

// documents
// factor out guide:
// move all mod to `main.rs` and remove this `lib.rs`
// is ok
